/*-*
 * FILENAME  :
 *    $HeadURL$
 *
 * STATUS  :
 *    $Revision$
 *
 *    $Author$
 *    $Date$
 *  
 *    
 * Copyright (c) 2011 Gonalge Ltda. All rights reserved.
 *
 ****************************************************************/

package org.gonalge.arbolrojonegro.type;

/**
 * 
 * @author Geremias Gonzalez
 */
public enum CasoArbol {
    CASO_UNO(1), CASO_DOS(2), CASO_TRES(3), CASO_CUATRO(4);

    private final int id;

    private CasoArbol(int id) {
        this.id = id;
    }

    public int getId() {
        return id;
    }

    public static CasoArbol fromId(int id) {
        CasoArbol caso = null;
        for (CasoArbol item : values()) {
            if (item.getId() == id) {
                caso = item;
                break;
            }
        }
        return caso;
    }
}
